// i18n
import i18n from './utils/lang';

// vue router
import router from '@/router/index';
// pinia
import store from '@/store';
import App from './App.vue';

import 'virtual:windi.css';
import 'virtual:windi-devtools';
import '@/assets/styles/index.scss';
import 'element-plus/theme-chalk/display.css';
import 'element-plus/theme-chalk/dark/css-vars.css'
import 'vant/es/notify/style';

import { openNoticeMessage } from './utils/format';

// 全局组件
import QrcodeVue from 'qrcode.vue';

// 引入自定义指令
import zlazy from '@/directives/index';
import 'swiper/css';
import Socket from '@/class/socket';

const app = createApp(App);

app.config.globalProperties.message = openNoticeMessage;
app.config.globalProperties.$Socket = Socket;

// 添加全局组件
app.component('QrcodeVue', QrcodeVue)

app.use(router).use(store);

app.use(i18n).use(zlazy);

app.mount('#app');
